<?php

include('SimpleImage.php');

function resizeThumb($in,$out='',$width=0,$height=0){

	$defaultWidth = 120;
	$defaultHeight = 80;

	if(!$width) $width = $defaultWidth;
	if(!$height) $height  = $defaultHeight;


	if(!$out) $out = $in;

	$si = new SimpleImage;
	$si->load($in);
	echo $si->resize($width,$height);
	$si->save($out);
}

?>
